<template>
	<view class="page" :style="themeColor">
		<view class="flex benben-position-layout flex flex-wrap align-center advertisementManage_flex_0"
			:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx'}">
			<view class='flex flex-wrap align-center justify-between flex-sub advertisementManage_fd0_0'>
				<view class='flex flex-wrap align-center' @tap.stop="handleJumpDiy" data-type="back" data-url="1">
					<text class='fu-iconfont2  advertisementManage_fd0_0_c0_c0' @tap.stop="handleJumpDiy"
						data-type="back" data-url="1">&#xE794;</text>
				</view>
				<view class='flex flex-wrap align-stretch justify-center flex-sub'>
					<text class='advertisementManage_fd0_0_c1_c0'>我的独白</text>
				</view>
				<view class='flex flex-wrap align-center advertisementManage_fd0_0_c2'>
				</view>
			</view>

		</view>
		<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
	
		<view class="loading_css" v-if="isShow">
			<u-loading size="36" color="#6A0002"></u-loading>
			<view class="loading_text">加载中</view>
		</view>
		<block v-else>
			<view class="monologue_content">
				<textarea v-model="usefInfo.monologue" name="" id="" cols="30" rows="10"></textarea>
			</view>
			
			<!---flex布局flex布局结束-->
			<view class="flex flex-direction flex-wrap align-center benben-position-layout flex advertisementManage_flex_2">
				<button class='advertisementManage_fd2_0' @tap.stop="submit">确定</button>
			</view>
		</block>
		
		<view :style="{height: '152rpx'}"></view>

	</view>
</template>
<script>
	import {
		validate
	} from '@/common/utils/validate.js'
	export default {
		components: {},


		data() {
			return {
				userid: "",
				usefInfo: {},
				isShow: true,
			};
		},
		computed: {
			themeColor() {
				return this.$store.getters.themeColor
			},

		},
		watch: {},
		onLoad(options) {
			this.getuser();
		},
		onUnload() {

		},
		onReady() {

		},
		onShow() {

		},
		onHide() {

		},
		onResize() {

		},
		onPullDownRefresh() {

		},
		onReachBottom(e) {

		},
		onPageScroll(e) {

		},
		methods: {
			//获取信息
			async getuser() {
				let id1 = uni.getStorageSync("USER_INFO")
				this.userid = id1.id
				let res = await this.$api.post(global.apiUrls.userinfo, {
					user_id: this.userid,
				});
				this.isShow = false
				if (res.data.code != 1) {
					this.$message.info(res.data.msg)
					return
				}
				this.usefInfo = res.data.data
				
			},
			submit() {
				if (!this.usefInfo.monologue) {
					this.$message.info('请输入独白');
					return;
				}
				this.$api.post(global.apiUrls.changeuesr, {
					head_img: this.usefInfo.head_img,
					user_nickname: this.usefInfo.user_nickname,
					birthday: this.usefInfo.birthday,
					weight: parseInt(this.usefInfo.weight),
					height: parseInt(this.usefInfo.height),
					waistline: this.usefInfo.waistline,
					bust: this.usefInfo.bust,
					hipline: this.usefInfo.hipline,
					email: this.usefInfo.email,
					mobile: this.usefInfo.mobile,
					work_place: this.usefInfo.work_place,
					career: this.usefInfo.career,
					monologue: this.usefInfo.monologue,
				}).then(res => {
					this.$message.info(res.data.msg);
					if (res.data.code == 1) {
						setTimeout(() => {
							uni.navigateBack();
						}, 800)
					}
				})
			},
		}
	};
</script>
<style lang="scss" scoped>
	.monologue_content {
		padding: 32rpx;
		textarea {
			width: 100%;
			height: 300rpx;
			background: #f6f7f9;
			border-radius: 16rpx;
			padding: 24rpx;
			font-size: 30rpx;
		}
	}
	
	
	.vip_flex_311 {
		background: #fff;
		width: 540rpx;
		background-size: 100% auto !important;
		border-radius: 16rpx 16rpx 16rpx 16rpx;
		padding: 32rpx 24rpx 24rpx 24rpx;
	}
	
	.vip_fd3_0_c0 {
		line-height: 45rpx;
		font-size: 32rpx;
		font-weight: 500;
		color: #000000;
	}
	
	.vip_fd3_1 {
		margin: 24rpx 0rpx 40rpx 0rpx;
	}
	
	::v-deep .vip_fd3_1_c0 {
		width: 750rpx;
		height: 160rpx;
	}
	
	.vip_flex_password_noActive_fd3_1_c0 {
		border: 1px solid #ccc;
		width: 68rpx;
		height: 68rpx;
		margin: 0rpx 5rpx 0rpx 5rpx;
	}
	
	.vip_fd3_2_c0 {
		background: #F2F2F2;
		border-radius: 16rpx 16rpx 16rpx 16rpx;
		font-size: 28rpx;
		color: #333;
		width: 234rpx;
		height: 72rpx;
		font-weight: 500;
		line-height: 72rpx;
	}
	
	.vip_fd3_2_c1 {
		background: #6a0002;
		border-radius: 16rpx 16rpx 16rpx 16rpx;
		font-size: 28rpx;
		color: #e6e6e6;
		width: 234rpx;
		height: 72rpx;
		font-weight: 500;
		line-height: 72rpx;
	}
	
	.vip_flex_password_active_fd3_1_c0 {
		border: 1px solid #409EFF;
		width: 68rpx;
		height: 68rpx;
		margin: 0rpx 5rpx 0rpx 5rpx;
	}
	
	
	
	
	.page {
		width: 100vw;
		overflow-x: hidden;
		min-height: calc(100vh - var(--window-bottom));
		background: var(--benbenbgColor0);
		background-size: 100% auto !important;
	}

	.MyInformation_picker5_0 {
		border-bottom: 1px solid #eee;
		background: #fff;
		padding: 0rpx 32rpx 0rpx 32rpx;
		line-height: 88rpx;
		border-radius: 25rpx 25rpx 0rpx 0rpx;
		background-size: 100% auto !important;
	}

	.MyInformation_picker5_0_c2 {
		color: #4781f5;
	}

	.advertisementManage_flex_0 {
		background: #fff;
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto !important;
	}

	.advertisementManage_fd0_0_c2 {
		width: 32rpx;
		height: 32rpx;
	}

	.advertisementManage_fd0_0_c1_c0 {
		font-size: 36rpx;
		font-weight: 500;
		color: #333;
		line-height: 88rpx;
	}

	.advertisementManage_fd0_0_c0_c0 {
		font-size: 32rpx;
		font-weight: 500;
		color: #333;
		line-height: 88rpx;
	}

	.advertisementManage_fd0_0 {
		margin: 0rpx 32rpx 0rpx 32rpx;
	}

	.advertisementManage_flex_1 {
		padding: 0rpx 32rpx 0rpx 32rpx;
	}

	.advertisementManage_fd1_0_c2 {
		font-size: 28rpx;
		color: rgba(191, 191, 191, 1);
	}

	.advertisementManage_fd1_0_c1 {
		text-align: right;
		margin: 0rpx 16rpx 0rpx auto;
		color: var(--benbenFontColor0);
		font-size: 32rpx;
	}

	.advertisementManage_fd1_0_c0 {
		color: #333333;
		font-size: 32rpx;
		font-weight: 400;
	}

	.advertisementManage_fd1_0 {
		border-bottom: 1px solid #eee;
		padding: 32rpx 0rpx 32rpx 0rpx;
	}

	.advertisementManage_flex_2 {
		width: 750rpx;
		height: 152rpx;
		margin-top: 72rpx;
		// overflow: hidden;
		// z-index: 10;
		// bottom: calc(0rpx + var(--window-bottom));
	}

	.advertisementManage_fd2_0 {
		background: #6A0002;
		border-radius: 44rpx 44rpx 44rpx 44rpx;
		font-size: 32rpx;
		color: #fff;
		width: 686rpx;
		height: 88rpx;
		line-height: 88rpx;
	}
</style>